package com.system.server.impl;

import com.system.dao.TypeDao;
import com.system.pojo.Role;
import com.system.server.TypeService;
import com.system.server.UserService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;

/**
 * @Author: E-mail:
 * @Version: 创建时间：2019年04月09日22:44
 * @Description: <描述>
 */
@Service
@Transactional(propagation = Propagation.REQUIRED,rollbackFor = Exception.class)
public class TypeServiceImpl implements TypeService {

    @Resource
    private TypeDao typeDao;


    @Override
    public Role findRoleByUserLoginName(String userName) {
        Role role = typeDao.selectRoleByUserLoginName(userName);
        return role;
    }
}
